/**
 * File转换Base64
 */
export const fileToBase64 = function(file){
  return new Promise((resolve) => {
    let reader = new FileReader();
    reader.onload = function (event) {
      resolve(event.target.result);
    };
    reader.readAsDataURL(file);
  })
}
